﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

using System.ComponentModel.DataAnnotations;
using System.ComponentModel;
using Sisocana.Core.Interfaces;

namespace Sisocana.Core.Models
{
    public class SiteModel : ISiteModel
    {
        
        public int id { get; set; }

        [DisplayName("Catastrophe Name")]
        [Required(ErrorMessage = "Catastrophe name required")]
        [StringLength(100, MinimumLength = 3, ErrorMessage = "The minimum length is 3 and the maximum length is 100")]
        public string nombreCatastrofe
        {
            get { return _nombreCatastrofe == null ? null : _nombreCatastrofe.Trim(); }
            set { _nombreCatastrofe = value; }
        }

        [DisplayName("Catastrophe Description")]
        [Required(ErrorMessage = "Catastrophe description required")]
        [StringLength(200, ErrorMessage = "The maximum length is 200")]
        public string descripcion
        {
            get { return _descripcion == null ? null : _descripcion.Trim(); }
            set { _descripcion = value; }
        }

        [DisplayName("Web Title")]
        [Required(ErrorMessage = "Web title required")]
        [StringLength(50, ErrorMessage = "The maximum length is 50")]
        public string tituloWeb
        {
            get { return _tituloWeb == null ? null : _tituloWeb.Trim(); }
            set { _tituloWeb = value; }
        }

        [DisplayName("Web Subtitle")]
        [Required(ErrorMessage = "Web Subtitle required")]
        [StringLength(50, ErrorMessage = "The maximum length is 50")]
        public string subtituloWeb
        {
            get { return _subtituloWeb == null ? null : _subtituloWeb.Trim(); }
            set { _subtituloWeb = value; }
        }

        [DisplayName("Catastrophe Date")]
        [Required(ErrorMessage = "Catastrophe date required")]
        public DateTime fecha
        {
            get { return _fecha; }
            set { _fecha = value; }
        }

        [DisplayName("Site Subdomain")]
        [Required(ErrorMessage = "Catastrophe subdomain required")]
        [StringLength(200, MinimumLength = 1, ErrorMessage = "The minimum length is 1 and the maximum length it's 200")]
        public string subdominio
        {
            get { return _subdominio == null ? null : _subdominio.Trim(); }
            set { _subdominio = value; }
        }

        [DisplayName("Footer Message")]
        [Required(ErrorMessage = "Footer message required")]
        [StringLength(500, ErrorMessage = "The maximum length is 500")]
        public string mensajeFooter
        {
            get { return _mensajeFooter == null ? null : _mensajeFooter.Trim(); }
            set { _mensajeFooter = value; }
        }

        [DisplayName("Header Message")]
        [StringLength(500, ErrorMessage = "The maximum length is 500")]
        [Required(ErrorMessage = "Header message required")]
        public string mensajeHeader
        {
            get { return _mensajeHeader == null ? null : _mensajeHeader.Trim(); }
            set { _mensajeHeader = value; }
        }

        [DisplayName("Site State")]
        public string estado
        {
            get { return _estado == null ? null : _estado.Trim(); }
            set { _estado = value; }
        }


        public string dir_css { get; set; }
        public string dir_master { get; set; }

        public string name_css { get; set; }
        public string name_master { get; set; }

        public byte[] logo { get; set; }
        public string logoExt { get; set; }
        public string logoNomb { get; set; }

        public string faceuser { get; set; }
        public string tweetuser { get; set; }
        public int tweetCant {get;set;}

        public int theigth { get; set; }
        public int twidth { get; set; }

        public string tweetsearch { get; set; }
        public string bsColor { get; set; }
        public string sColor { get; set; }
        public string btColor { get; set; }
        public string tColor { get; set; }

        

        public IList<RedSocialAsociadoModel> redesSociales { get; set; }

        public string videoTag { get; set; }
        public string videoKey { get; set; }
        public int videoSize { get; set; }
        public string videoTipo { get; set; }
        public int videoWidth { get; set; }
        public int videoHeigth { get; set; }

        public string imagekey { get; set; }
        public string imageSecret { get; set; }
        public string imageTag { get; set; }
        public string imageColor { get; set; }
        public int imageCant { get; set; }
        public int imageWidth { get; set; }
        public int imageHeigth { get; set; }
        public string imageGallery { get; set; }

        public IList<NoticiaAsociadaModel> sources { get; set; }


        #region Variables

        private string _nombreCatastrofe;
        private string _descripcion;
        private string _mensajeHeader;
        private string _mensajeFooter;
        private string _subdominio;
        private DateTime _fecha;
        private string _subtituloWeb;
        private string _tituloWeb;
        private string _estado;

        #endregion
    }
}